import Vue from 'vue'
import Router from 'vue-router'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'login',
      component: () => import('./../components/login.vue')
    },
    {
      path: '/reg',
      name: 'reg',
      component: () => import('../components/reg.vue')
    },
    {
      path: '/index',
      name: 'index',
      component: () => import('./../components/index.vue'),
      children: [
        {
          path: '/',
          name: 'index',
          component: () => import('./../view/index/default.vue')
        },
        {
          path: '/home',
          name: '主页',
          component: () => import('./../view/index/home.vue')
        },
        {
          path: '/userDetail',
          name: '用户中心',
          component: () => import('./../view/user/userDetail.vue')
        },
        {
          path: '/userEmploye',
          name: '就业信息',
          component: () => import('./../view/user/userEmploye.vue')
        },
        {
          path: '/collegevisualization',
          name: '学院可视化',
          component: () => import('./../view/visualization/collegevisualization.vue')
        }
      ]
    }
  ]
})
